<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib prefix="f" uri="http://java.sun.com/jsf/core"%>
<%@ taglib prefix="h" uri="http://java.sun.com/jsf/html"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
	<f:view>

		<h:form>

			<fieldset>
				<legend style="margin-left: 0px;">Cadastro de Professor</legend>

				<div id="cads">

					<h:panelGrid columns="2">

						<h:outputText value="#{msgs['professor.nome']}" />

						<h:inputText id="nomeMedausente"
							value="#{ProfessorBean.professor.nome}" required="true"
							requiredMessage="#{msgs['professor.nomeAusente']}"
							style="width:200px;" />


						<h:outputText value="#{msgs['professor.sexo']}" />

						<h:selectOneListbox value="#{ProfessorBean.professor.sexo}"
							id="prof_sexo" size="1" style="width:205px;" styleClass="campo">
							<f:selectItem itemValue="Selecione" />
							<f:selectItem itemValue="Masculino" />
							<f:selectItem itemValue="Feminino" />
						</h:selectOneListbox>

						<h:outputText value="#{msgs['professor.dtnascimento']}"
							styleClass="campo" />
						<h:inputText id="dtnasc"
							value="#{ProfessorBean.professor.data_nascimento}"
							label="Data inválido"
							converterMessage="#{msgs['professor.data.invalida']}"
							required="true"
							requiredMessage="#{msgs['professor.data.ausente']}"
							style="width:200px;" styleClass="campo">
							<f:convertDateTime pattern="dd-MM-yyyy" />
						</h:inputText>


						<h:outputText value="#{msgs['professor.naturalidade']}" />

						<h:inputText id="naturalidadeAusente"
							value="#{ProfessorBean.professor.local_nascimento}"
							required="true"
							requiredMessage="#{msgs['professor.naturalidadeAusente']}"
							style="width:200px;" />


						<h:outputText value="#{msgs['professor.cidade']}" />

						<h:inputText id="cidadeAusente"
							value="#{ProfessorBean.professor.cidade}" required="true"
							requiredMessage="#{msgs['professor.cidadeAusente']}"
							style="width:200px;" />


						<h:outputText value="#{msgs['professor.rua']}" />

						<h:inputText id="ruaAusente"
							value="#{ProfessorBean.professor.rua}" required="true"
							requiredMessage="#{msgs['professor.ruaAusente']}"
							style="width:200px;" />

						<h:outputText value="#{msgs['professor.bairro']}" />

						<h:inputText id="bairroAusente"
							value="#{ProfessorBean.professor.bairro}" required="true"
							requiredMessage="#{msgs['professor.bairroAusente']}"
							style="width:200px;" />


						<h:outputText value="#{msgs['professor.numero']}" />

						<h:inputText id="numeroAusente"
							value="#{ProfessorBean.professor.numero}" required="true"
							requiredMessage="#{msgs['professor.numeroAusente']}"
							style="width:200px;" />

						<h:outputText value="#{msgs['professor.salario']}" />

						<h:inputText id="salarioAusente"
							value="#{ProfessorBean.professor.salario}" required="true"
							requiredMessage="#{msgs['professor.salarioAusente']}"
							style="width:200px;" />


						<h:outputText value="#{msgs['professor.dtAdmissao']}"
							styleClass="campo" />
						<h:inputText id="dtAdm"
							value="#{ProfessorBean.professor.data_adimissao}"
							label="Data inválido"
							converterMessage="#{msgs['professor.data.invalida']}"
							required="true"
							requiredMessage="#{msgs['professor.data.ausente']}"
							style="width:200px;" styleClass="campo">
							<f:convertDateTime pattern="dd-MM-yyyy" />
						</h:inputText>


						<h:outputText value="#{msgs['professor.regimeTrabalho']}" />
						<h:selectOneListbox
							value="#{ProfessorBean.professor.regime_trabalho}" id="reg_trab"
							size="1" style="width:205px;" styleClass="campo">
							<f:selectItem itemValue="Selecione" />
							<f:selectItem itemValue="Celetista" />
							<f:selectItem itemValue="Estatutário" />

						</h:selectOneListbox>


						<h:outputText value="#{msgs['professor.titulacao']}" />
						<h:selectOneListbox value="#{ProfessorBean.professor.titulacao}"
							id="titul" size="1" style="width:205px;" styleClass="campo">
							<f:selectItem itemValue="Selecione" />
							<f:selectItem itemValue="Graduado" />
							<f:selectItem itemValue="Mestre" />
							<f:selectItem itemValue="Doutor" />

						</h:selectOneListbox>

					</h:panelGrid>


					<h:commandButton type="submit" value="Cadastrar"
						action="#{ProfessorBean.CadastrarProfessor}" styleClass="botoes"
						style="margin-left: 0px;" />

					<h:commandButton value="Cancelar" action="cancelar"
						immediate="true" styleClass="botoes" />

					<br>
					<hr>

				</div>

				<div="Avisos">
					<fieldset>
						<legend style="margin-left: 0px;">Avisos</legend>

						<h:messages style="color:red;"></h:messages>
					</fieldset>

				</div>

			</fieldset>

		</h:form>



	</f:view>
</body>
</html>